-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
2597: Add epic relations #183
Conversation
$epic = new Epic(); | ||
$epic->setTitle($epicTitle); | ||
$this->entityManager->persist($epic); | ||
$this->entityManager->flush(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need for flush here.
src/Entity/IssueEpic.php
Outdated
@@ -0,0 +1,17 @@ | |||
<?php |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this file.
@@ -271,6 +274,26 @@ public function syncIssuesForProject(int $projectId, ?callable $progressCallback | |||
} | |||
} | |||
|
|||
$epicArray = explode(',', $issueDatum->epicName); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of exploding here, issueDatum should include an array of Epics, and LeantimeDataProvider and JiraDataProvider should supply the array of epics.
…g service initialization.
… from issueDatum.
…d persisting epics.
src/Model/Invoices/IssueData.php
Outdated
@@ -2,6 +2,7 @@ | |||
|
|||
namespace App\Model\Invoices; | |||
|
|||
use App\Entity\Epic; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should mix Entity with Model.
The collection $epics could just be an array of strings instead. Then you can map to Epic entity in DataSynchronizationService.
src/Service/JiraApiService.php
Outdated
@@ -53,6 +55,7 @@ public function __construct( | |||
protected readonly float $weekGoalLow, | |||
protected readonly float $weekGoalHigh, | |||
protected readonly string $sprintNameRegex, | |||
private readonly EpicRepository $epicRepository, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should not do anything with Entities in the ApiServices.
Co-authored-by: Troels Ugilt Jensen <[email protected]>
Co-authored-by: Troels Ugilt Jensen <[email protected]>
Co-authored-by: Troels Ugilt Jensen <[email protected]>
Co-authored-by: Troels Ugilt Jensen <[email protected]>
Co-authored-by: Troels Ugilt Jensen <[email protected]>
Co-authored-by: Troels Ugilt Jensen <[email protected]>
…y-report Invoicing rate report
…iod-average-etc 3489: workload report period average + etc
Link to ticket
2597
Description
This PR adds relations for epics.
Screenshot of the result
N/A
Checklist